The eraser tool is used to erase sections of your painting.
Position the cursor over something you want to erase and drag the mouse. Everything you drag the eraser over will be deleted and replaced with the background color (the eraser color).
Double click on the eraser icon to automatically erase the contents of the Canvas window.